home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
MacFormat 1996 October
/
MacFormat CD Edition MF42 (October 1996).ISO
/
mac
/
Shareware City
/
Developers
/
FFTs for RISC 1.2
/
rffttest.m
< prev
next >
Encoding:
Amiga
Atari
Commodore
DOS
FM Towns/JPY
Macintosh
Macintosh JP
Macintosh to JP
NeXTSTEP
RISC OS/Acorn
Shift JIS
UTF-8
Wrap
Text File
|
1996-06-27
|
330 b
|
21 lines
|
[
TEXT/MATL
]
N=64;
j=sqrt(-1);
a=ones(N,1);
row=0;
for i1=1:2:N;
a(i1) = sqrt(row+i1-1+.77777);
a(i1+1) = (row+i1-1+.22222)*(row+i1-1+.22222) / N - N/2;
end;
a(1)=N+3;
a(3)=1-N;
A2=fft(a);
A=A2(1:N/2);
A(1)=A(1)+j*A2(N/2+1);
a1=reshape(a,N/2,2);
if N<=32
A
a1
end
max(abs(A-atrans))./(max(abs(A))/N)
max(abs(a-aitrans))./(max(abs(a))/N)